var express = require('express');
var router = express.Router();
var registerController = require("../controllers/register_controller")
router.post('/register', function (req, res, next) {
    const {
        SecondaryCollege,
        className,
        student_Number,
        password,
        studentName,
        grade
    } = req.body
    console.log(SecondaryCollege,
        className,
        student_Number,
        password,
        studentName,grade);
    registerController.doStudentRegister({
        SecondaryCollege,
        className,
        student_Number,
        password,
        studentName,grade
    }, ["注册失败", "注册成功"], (result) => {
        res.json(result)
    })
});

module.exports = router;